package com.kingdee.model;

import com.kingdee.Utils.TimeVaildCheck;

/**
 * Created by Administrator on 2016/12/27.
 */
public class WorkTime {
    private String morningComeTime = "8:30";
    private String morningGoTime = "11:45";
    private String affternoonComeTime = "13:00";
    private String affternoonGoTime = "17:45";

    public String getMorningComeTime() {
        return morningComeTime;
    }

    public void setMorningComeTime(String morningComeTime) {
        this.morningComeTime = morningComeTime;
    }

    public String getMorningGoTime() {
        return morningGoTime;
    }

    public void setMorningGoTime(String morningGoTime) {
        this.morningGoTime = morningGoTime;
    }

    public String getAfternoonComeTime() {
        return affternoonComeTime;
    }

    public void setAffternoonComeTime(String affternoonComeTime) {
        this.affternoonComeTime = affternoonComeTime;
    }

    public String getAfternoonGoTime() {
        return affternoonGoTime;
    }

    public void setAfternoonGoTime(String affternoonGoTime) {
        this.affternoonGoTime = affternoonGoTime;
    }

    public WorkTime(){}

    public WorkTime(String morningComeTime){
        if(TimeVaildCheck.isTimeVaild(morningComeTime)){
            this.morningComeTime = morningComeTime;
        }else{
            System.out.println("morningComeTime is wrongs");
        }
    }
    public WorkTime(String morningComeTime,String morningGoTime){
        if(TimeVaildCheck.isTimeVaild(morningComeTime)){
            this.morningComeTime = morningComeTime;
        }else{
            System.out.println("morningComeTime is wrongs");
        }
        if(TimeVaildCheck.isTimeVaild(morningGoTime)){
            this.morningGoTime = morningGoTime;
        }else{
            System.out.println("morningGoTime is wrongs");
        }
    }
    public WorkTime(String morningComeTime,String morningGoTime,String affternoonComeTime){
        if(TimeVaildCheck.isTimeVaild(morningComeTime)){
            this.morningComeTime = morningComeTime;
        }else{
            System.out.println("morningComeTime is wrongs");
        }
        if(TimeVaildCheck.isTimeVaild(morningGoTime)){
            this.morningGoTime = morningGoTime;
        }else{
            System.out.println("morningGoTime is wrongs");
        }
        if(TimeVaildCheck.isTimeVaild(affternoonComeTime)){
            this.affternoonComeTime = affternoonComeTime;
        }else{
            System.out.println("affternoonComeTime is wrongs");
        }
    }
    public WorkTime(String morningComeTime,String morningGoTime,String affternoonComeTime,String affternoonGoTime){
        if(TimeVaildCheck.isTimeVaild(morningComeTime)){
            this.morningComeTime = morningComeTime;
        }else{
            System.out.println("morningComeTime is wrongs");
        }
        if(TimeVaildCheck.isTimeVaild(morningGoTime)){
            this.morningGoTime = morningGoTime;
        }else{
            System.out.println("morningGoTime is wrongs");
        }
        if(TimeVaildCheck.isTimeVaild(affternoonComeTime)){
            this.affternoonComeTime = affternoonComeTime;
        }else{
            System.out.println("affternoonComeTime is wrongs");
        }
        if(TimeVaildCheck.isTimeVaild(affternoonGoTime)){
            this.affternoonGoTime = affternoonGoTime;
        }else{
            System.out.println("affternoonGoTime is wrongs");
        }
    }
}
